<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>JEECMS Administrator's Control Panel - powered by jeecms</title>
	<#include "/cms_sys/head.html"/>
	<style type="text/css">        
		*{margin:0;padding:0}
		a:focus {outline:none;}
		html{height:100%;overflow:hidden;}
		body{height:100%;}
		#top{ background-color:#1d63c6; height:69px; width:100%;}
		.logo{width:215px; height:69px;}
		.topbg{background:url(${base}/res/cms/img/admin/top-tbg.png) no-repeat; height:38px;}
		.login-welcome{padding-left:20px; color:#fff; font-size:12px;background:url(${base}/res/cms/img/admin/topbg.gif) no-repeat;}
		.login-welcome a:link,.login-welcome a:visited{color:#fff; text-decoration:none;}
		
		#welcome {color: #FFFFFF;padding: 0 30px 0 5px;}
		#logout {color: #FFFFFF; padding-left: 5px;}
		
		.nav{height:31px; overflow:hidden;}
		.nav-menu{background:url(${base}/res/cms/img/admin/bg.png) repeat-x; height:31px; list-style:none; padding-left:20px; font-size:14px;}
		.nav .current {background: url(${base}/res/cms/img/admin/navcurrbg.gif) no-repeat 0px 2px; color:#fff; width:72px; text-align:center;} 
		.nav .current a{color:#fff;}
		.nav-menu li {height:31px;text-align:center; line-height:31px; float:left; }
		.nav-menu li a{color:#2b2b2b; font-weight:bold;}
		.nav-menu li.sep{background: url(${base}/res/cms/img/admin/step.png) no-repeat; width:2px; height:31px; margin:0px 5px;}
		.nav .normal{width:72px; text-align:center;}
		.top-bottom{width:100%; background: url(${base}/res/cms/img/admin/bg.png) repeat-x 0px -34px; height:3px;}
		.undis{display:none;}
		.dis{display:block;}
	</style>

	<script type="text/javascript">
	function g(o){
		return document.getElementById(o);
	}
	function HoverLi(m,n,counter){
		for(var i=1;i<=counter;i++){
			g('tb_'+m+i).className='normal';
		}
		g('tb_'+m+n).className='current';
	}
	function countUnreadMsg(){
		 $.post("message/v_countUnreadMsg.do", {}, function(data) {
				if(data.result){
					 $("#countDiv").html(""+data.count+"");
				}else{
					alert("<@s.m 'cmsMessage.noLogin'/>");
				}
			}, "json");
		 setTimeout( "countUnreadMsg() ",1000*60*10);    
	}
	$(function(){
		$('a').bind("focus", function(){   
		    $(this).blur();   
		}); 
		countUnreadMsg();
	});
	setTimeout( "countUnreadMsg() ",1000*60*10); 
	function mapDialog(){
		var result=window.showModalDialog("map.do","","dialogHeight:600px;dialogWidth:800px;center:yes;resizable: yes;");
		if(result!=null){
			var href=result.split(";")[0];
			var target=result.split(";")[1];
			if(target=="rightFrame"){
					window.parent.mainFrame.document.getElementById(target).src=href;
					var rightFrameSrc=window.parent.mainFrame.document.getElementById(target).src;
					 if(rightFrameSrc.indexOf("frame")>=0){
						window.parent.mainFrame.document.getElementById(target).src=rightFrameSrc.split("frame/")[0]+rightFrameSrc.split("frame/")[1];
						}
				}
			else {
				 	window.parent.document.getElementById(target).src=href;
				}
			}
	}
	</script>
</head>
	<body>
		<div id="top">
		     <div class="top">
		     	<table width="100%" border="0" cellspacing="0" cellpadding="0">
		        	 <tr>
		        	 	<td width="215"><div class="logo"><img src="${base}/res/cms/img/admin/logo.png" width="215" height="69" /></div></td>
		        	 	<td valign="top">
		        	 		 <div class="topbg">
		        	 		 	 <div class="login-welcome">
		        	 		 	 	<table width="100%" border="0" cellspacing="0" cellpadding="0">
		        	 		 	 		<tr>
		        	 		 	 			 <td width="420" height="38">
		        	 		 	 			 	<img src="${base}/res/cms/img/admin/welconlogin-icon.png"/><span id="welcome"><@s.ma code="global.admin.welcome" args=[user.username]/></span>
		        	 		 	 			 	<img src="${base}/res/cms/img/admin/loginout-icon.png"/><a href="logout.do?returnUrl=index.do" target="_top" id="logout" onclick="return confirm('<@s.m "global.confirm.logout"/>');" ><@s.m "global.admin.logout"/></a>
		        	 		 	 			 	<img src="${base}/res/cms/img/admin/message-unread.png"/>&nbsp;<a href="message/v_list.do" target="rightFrame">您有<span id="countDiv"></span>条信息未读</a>
		        	 		 	 			 </td>
		        	 		 	 			 <td align="right">
		        	 		 	 			 	<form action="index.do" target="_top" method="get">
		        	 		 	 			 		<select name="${siteParam}" onchange="this.form.submit();">
		        	 		 	 			 			<#list siteList as s>
										              		<option value="${s.siteId}"<#if s.siteId==site.siteId> selected="selected"</#if>>${s.siteName}</option>
										              	</#list>
		        	 		 	 			 		</select>
		        	 		 	 			 	</form>
		        	 		 	 			 </td>
		        	 		 	 		</tr>
		        	 		 	 	</table>
		        	 		 	 </div>
		        	 		 	 <div class="nav">
			                     	  <table width="100%" border="0" cellspacing="0" cellpadding="0">
			                              <tr>
			                                <td style="background-image:url('${base}/res/cms/img/admin/nav-left.png')" width="14" height="31"></td>
			                                <td>
			                                	<ul class="nav-menu">
			                                    	<li class="current" id="tb_11" onclick="HoverLi(1,1,10);"><a href="main.do" target="mainFrame"><@s.m "global.admin.home"/></a></li>
													<@cms_perm url="/frame/channel_main.do">			
														<li class="sep"></li><li class="normal" id="tb_12" onclick="HoverLi(1,2,10);"><a href="frame/channel_main.do" target="mainFrame"><@s.m "cms.function.channel"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/content_main.do">
														<li class="sep"></li><li class="normal" id="tb_13" onclick="HoverLi(1,3,10);"><a href="frame/content_main.do" target="mainFrame"><@s.m "cms.function.content"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/template_main.do">
														<li class="sep"></li><li class="normal" id="tb_14" onclick="HoverLi(1,4,10);"><a href="frame/template_main.do" target="mainFrame"><@s.m "cms.function.template"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/resource_main.do">
														<li class="sep"></li><li class="normal" id="tb_15" onclick="HoverLi(1,5,10);"><a href="frame/resource_main.do" target="mainFrame"><@s.m "cms.function.resource"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/assistant_main.do">
														<li class="sep"></li><li class="normal" id="tb_16" onclick="HoverLi(1,6,10);"><a href="frame/assistant_main.do" target="mainFrame"><@s.m "cms.function.assistant"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/maintain_main.do">
														<li class="sep"></li><li class="normal" id="tb_17" onclick="HoverLi(1,7,10);"><a href="frame/maintain_main.do" target="mainFrame"><@s.m "cms.function.maintain"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/generate_main.do">
														<li class="sep"></li><li class="normal" id="tb_18" onclick="HoverLi(1,8,10);"><a href="frame/generate_main.do" target="mainFrame"><@s.m "cms.function.generate"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/user_main.do">
														<li class="sep"></li><li class="normal" id="tb_19" onclick="HoverLi(1,9,10);"><a href="frame/user_main.do" target="mainFrame"><@s.m "cms.function.user"/></a></li>
													</@cms_perm>
													<@cms_perm url="/frame/config_main.do">
														<li class="sep"></li><li class="normal" id="tb_110" onclick="HoverLi(1,10,10);"><a href="frame/config_main.do" target="mainFrame"><@s.m "cms.function.config"/></a></li>
													</@cms_perm>
												</ul>
			                                </td>
			                              </tr>
			                    	</table>
                     			</div>  
		        	 		 </div>
		        	 	</td>
		        	 </tr> 
		        </table>
		     </div>
		</div>
		<div class="top-bottom"></div>
	</body>
</html>